package org;

/**
 * @Author: xwg
 * @CreateDate: 2021/11/19
 */

          //OO  object orient
public class Divide {

//  属性        field  property
    private Integer n = 11;
//构造函数
//    public Divide(Integer a){
//        this.n=a;
//    }

    public Divide(Integer n) {
        this.n = n;
    }

    //    方法     method function
    public void printN() {
        for (int j = 1; j <= this.n; j++) {

            Integer first = j;
            for (int i = 1; i <= first; i++) {
                Integer result = first * i;
                System.out.print(first + "x" + i + "=" + result + " ");
            }
            System.out.println();
        }
    }

    public static void main(String[] args) {
        Divide divide = new Divide(8);
        divide.printN();
    }

}
